package beautysalonsystem.mapper;

import beautysalonsystem.pojo.Admin;
import beautysalonsystem.pojo.Customer;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

@Mapper
public interface UserMapper {

    //通过phone查询admin信息
    @Select("select * from admin_tb where phone = #{phone}")
    Admin getAdminByPhone(String phone);

    //通过phone查询customer信息
    @Select("select * from customer_tb where phone = #{phone}")
    Customer getCustomerByPhone(String phone);

    //通过id查询customer信息
    @Select("select * from customer_tb where id = #{id}")
    Customer getCustomerById(Integer id);


}
